package com.learn.project2.model.vo.admin.collect;

import com.learn.project2.bean.MarketCollect;
import com.learn.project2.model.vo.admin.user.UserListVO;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.util.List;

/**
 * @description: 会员收藏的响应数据接收
 * @author wxy
 * @date 2022-01-08 10:16
 * @version 1.0
 */
@NoArgsConstructor
@Data
public class CollectListVO {

    private Integer total;
    private Integer pages;
    private Integer limit;
    private Integer page;
    private List<MarketCollect> list;

    public static CollectListVO data(long total, Integer pages, Integer limit, Integer page, List list) {
        CollectListVO collectListVO = new CollectListVO();
        collectListVO.setTotal((int) total);
        collectListVO.setPages(pages);
        collectListVO.setPage(page);
        collectListVO.setLimit(limit);
        collectListVO.setList(list);
        return collectListVO;
    }

}
